<#include "/@inc/funcMacros.ftl"> 
<#include "/@inc/copyright.txt">
<#assign className = TriaGram + "E" + Prefix + LateType + "Edit">
<#assign intfName = TriaGram + "I" + Prefix + LateType>
<#assign baseName = TriaGram + Prefix + LateType>
<@pp.renameOutputFile name=className+".cpp">
</@pp.renameOutputFile>

//Local framework
#include "${className}.h"
#include "${baseName}Cmd.h" // The command to edit the user feature

// ObjectModelerBase framework
#include "CATISpecObject.h"   

// Visualization framework
#include "CATPathElement.h"

//----------------------------------------------------------------------------
// To create the TIE Object
#include "TIE_CATIEdit.h"
TIE_CATIEdit( ${className});

// To declare that the class 
// is a DataExtension of (late type) CAAUdfLoft
//
CATImplementClass( ${className},
                   DataExtension,
                   CATBaseUnknown,
                   ${LateType});

//-----------------------------------------------------------------------------

${className}::${className}()
{
 }

//-----------------------------------------------------------------------------

${className}::~${className}()
{
}
 
//-----------------------------------------------------------------------------

CATCommand * ${className}::Activate (CATPathElement *  iPath)
{
   CATCommand * pCommand = NULL ;
   if ( NULL != iPath ) 
   {
       CATBaseUnknown* piUk = iPath->CurrentElement();

       if ( NULL != piUk ) 
       {
		   CATISpecObject_var spiSpecOnEditFeature = piUk;
			if (NULL_var != spiSpecOnEditFeature)
			{
			  // creates the edition command
				  pCommand =  new ${baseName}( spiSpecOnEditFeature, 0 );
			}
       }   
   }
   return pCommand ;
}
